import { getCachedData } from '../services/storageService';

// const DEFAULT_CONFIG = {
//   HOST: 'http://192.168.1.142:8849',
//   KEY: '3bb78245-26d3-4df5-82fd-1f00027e7de2',
//   WS_HOST: 'ws://192.168.1.142:8849'
// };

export const API_CONFIG = {
  get HOST() {
    return getCachedData('apiHost');
  },
  get KEY() {
    return getCachedData('apiToken');
  },
  get WS_HOST() {
    return getCachedData('apiHost')?.replace('http', 'ws');
  }
};